<script setup lang="ts">

const props = defineProps<{
  size: number
}>()
</script>

<template>
  <div class="spinner" :style="{ width: props.size + 'px', height: props.size + 'px'}"></div>
</template>

<style scoped>
.spinner {
  width: 40px;
  height: 40px;
  border: 2px solid #2f80ed;
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
</style>